package org.jeecg.glr.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.Transient;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * @Description: 路灯灯杆管理
 * @Author: jeecg-boot
 * @Date:   2020-03-05
 * @Version: V1.0
 */
@Data
@TableName("glr_light_pole")
public class GlrLightPole implements Serializable {
    private static final long serialVersionUID = 1L;
    
	/**主键*/
	@TableId(type = IdType.UUID)
    private String id;
	/**编号*/
	@Excel(name = "编号", width = 15)
    private String code;
    /**名称*/
    @Excel(name = "名称", width = 15)
    private String name;
	/**灯杆灯型 1普通灯杆，2智慧灯杆，3合杆*/
	@Excel(name="灯杆类型",width=15,replace={"普通灯杆_1","智慧灯杆_2","合杆_3"})
	@Dict(dicCode = "glr_light_pole_type")
	private String lightPoleType;
	/**经度*/
	@Excel(name = "经度", width = 15)
    private String longitude;
	/**纬度*/
	@Excel(name = "纬度", width = 15)
    private String latitude;
	/**描述*/
	@Excel(name = "描述", width = 512)
    private String memo;
	/**项目编号*/
	@Excel(name = "项目编号", width = 15)
	private String projectCode;
	@TableField(exist = false)
	private String projectName;
	/**所属公司*/
	@Excel(name = "所属公司", width = 15)
    private String sysCompanyCode;

	/**是否有音柱*/
	@Excel(name = "是否有音柱", width = 2)
	private String radioYn;
	/**是否有LED屏*/
	@Excel(name = "是否有LED屏", width = 2)
	private String ledYn;
	/**是否有路灯*/
	@Excel(name = "是否有路灯", width = 2)
	private String lightYn;
	/**是否有网关*/
	@Excel(name = "是否有网关", width = 2)
	private String gatewayYn;
	/**是否有传感器*/
	@Excel(name = "是否有传感器", width = 2)
	private String sensorYn;
	/**是否有摄像头*/
	@Excel(name = "是否有摄像头", width = 2)
	private String videoYn;


	/**创建人*/
	@Excel(name = "创建人", width = 15)
    private String createBy;
	/**创建日期*/
	@Excel(name = "创建日期", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date createTime;
	/**更新人*/
	@Excel(name = "更新人", width = 15)
    private String updateBy;
	/**更新日期*/
	@Excel(name = "更新日期", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
	/**所属部门*/
	@Excel(name = "所属部门", width = 15)
    private String sysOrgCode;

	/** 同步网关*/
	@Transient
	private transient String synchronizationGateWay;
	/**
	 * 是否智慧灯杆
	 */
	@Transient
	private transient String isWisdom;
	@TableField(exist = false)
	private Integer poleNum;

	/** 设备列表*/
	@TableField(exist = false)
	private List<GlrLightPoleDevice> lightPoleDeviceList;

}
